package com.zdsoft.finance.product.entity;

import java.math.BigDecimal;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.zdsoft.framework.core.common.domain.BaseEntity;


/**
 * 费用项
 * @author longwei
 * @date 2016/11/08
 * @version 1.0
 */
@Entity
@Table(name="zf_product_fee_item")
public class ProductFeeItem extends BaseEntity{

	/**
	 * 费用项
	 */
	@Column(length=32)
	private String code;
	
	/**
	 * 费用项名称
	 */
	@Column(length=255)
	private String name;
	
	/**
	 * 计费方式
	 */
	@Column(length=32)
	private String billingMethodCd;
	
	/**
	 * 计费方式名称
	 */
	@Column(length=255)
	private String billingMethodNm;
	
	/**
	 * 费率
	 */
	@Column
	private Double rate;
	
	/**
	 * 金额
	 */
	@Column(precision=15,scale=2)
	private BigDecimal amount;
	
	/**
	 * 备注
	 */
	@Lob
	private String remark;
	
	/**
	 * 所属产品
	 */
	@ManyToOne
	@JoinColumn(name="product_id")
	private Product product;

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getBillingMethodCd() {
		return billingMethodCd;
	}

	public void setBillingMethodCd(String billingMethodCd) {
		this.billingMethodCd = billingMethodCd;
	}

	public String getBillingMethodNm() {
		return billingMethodNm;
	}

	public void setBillingMethodNm(String billingMethodNm) {
		this.billingMethodNm = billingMethodNm;
	}

	public Double getRate() {
		return rate;
	}

	public void setRate(Double rate) {
		this.rate = rate;
	}

	public BigDecimal getAmount() {
		return amount;
	}

	public void setAmount(BigDecimal amount) {
		this.amount = amount;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public Product getProduct() {
		return product;
	}

	public void setProduct(Product product) {
		this.product = product;
	}

}
